import Vue from 'vue'
import App from './App.vue'
import VueRouter from "vue-router"
import ElementUI from "element-ui"
import 'element-ui/lib/theme-chalk/index.css';


import Login from "./components/login/Login"
import Index from "./components/index/Index"
import OrderList from "./components/order/OrderList"
import OrderDeatils from "./components/order/OrderDeatils"

Vue.config.productionTip = false
Vue.use(VueRouter)
Vue.use(ElementUI)


//只要访问跟路径/,就会重定向 /login
//进入Login 页面
var router = new VueRouter({
	routes:[
		{path:'/',redirect:'/login'},
		{path:'/login',component:Login},
		{path:'/orderList',component:OrderList},
		{path:'/orderDeatils',component:OrderDeatils},
		{path:'/index',component:Index}
	
	]
})




new Vue({
  render: h => h(App),
  router
}).$mount('#app')
